package service.facade.user;

import domain.User;
import exceptions.UserAlreadyExistsException;

import javax.persistence.NonUniqueResultException;

public interface UserService {


    User findUserById(long userId);

    User findUserByLogin(String userName) throws NonUniqueResultException;

    void registration(User user) throws UserAlreadyExistsException, Exception;

    boolean changePassword(User object, String oldPassword, String newPassword) throws Exception;
}
